Click here to Skip to main content
15,915,019 members
Home / Discussions / Database
   

Database

 
AnswerRe: sql script Pin
Ingo26-Sep-12 21:44
Ingo26-Sep-12 21:44 
AnswerRe: sql script Pin
J4amieC26-Sep-12 21:46
J4amieC26-Sep-12 21:46 
GeneralRe: sql script Pin
sindhuan26-Sep-12 23:30
sindhuan26-Sep-12 23:30 
AnswerRe: sql script Pin
Ingo27-Sep-12 0:07
Ingo27-Sep-12 0:07 
GeneralRe: sql script Pin
Eddy Vluggen27-Sep-12 0:22
professionalEddy Vluggen27-Sep-12 0:22 
GeneralRe: sql script Pin
J4amieC27-Sep-12 1:06
J4amieC27-Sep-12 1:06 
QuestionLine line is a select statement. Pin
vanikanc26-Sep-12 8:22
vanikanc26-Sep-12 8:22 
AnswerRe: Line line is a select statement. Pin
jschell26-Sep-12 8:37
jschell26-Sep-12 8:37 
GeneralRe: Line line is a select statement. Pin
vanikanc26-Sep-12 8:39
vanikanc26-Sep-12 8:39 
GeneralRe: Line line is a select statement. Pin
jschell27-Sep-12 9:57
jschell27-Sep-12 9:57 
AnswerRe: Line line is a select statement. Pin
Niju126-Sep-12 22:28
Niju126-Sep-12 22:28 
AnswerRe: Line line is a select statement. Pin
Ingo26-Sep-12 23:04
Ingo26-Sep-12 23:04 
QuestionAttendance and leave of employees Pin
Amr Muhammed25-Sep-12 13:06
Amr Muhammed25-Sep-12 13:06 
AnswerRe: Attendance and leave of employees Pin
Ingo25-Sep-12 20:50
Ingo25-Sep-12 20:50 
GeneralRe: Attendance and leave of employees Pin
Andrei Straut25-Sep-12 21:03
Andrei Straut25-Sep-12 21:03 
GeneralRe: Attendance and leave of employees Pin
Ingo25-Sep-12 21:19
Ingo25-Sep-12 21:19 
GeneralRe: Attendance and leave of employees Pin
Andrei Straut25-Sep-12 21:20
Andrei Straut25-Sep-12 21:20 
QuestionConvert datetime to certain format Pin
vanikanc25-Sep-12 9:09
vanikanc25-Sep-12 9:09 
AnswerRe: Convert datetime to certain format Pin
Ingo25-Sep-12 20:58
Ingo25-Sep-12 20:58 
QuestionSql server topics and materials Pin
Azizullahazizi24-Sep-12 18:32
Azizullahazizi24-Sep-12 18:32 
AnswerRe: Sql server topics and materials Pin
Andrei Straut24-Sep-12 20:12
Andrei Straut24-Sep-12 20:12 
AnswerRe: Sql server topics and materials Pin
Sandeep Mewara24-Sep-12 20:23
mveSandeep Mewara24-Sep-12 20:23 
QuestionSQL Search within a table Pin
veon cheng24-Sep-12 9:31
veon cheng24-Sep-12 9:31 
AnswerRe: SQL Search within a table Pin
Corporal Agarn25-Sep-12 1:08
professionalCorporal Agarn25-Sep-12 1:08 
GeneralRe: SQL Search within a table Pin
veon cheng25-Sep-12 3:37
veon cheng25-Sep-12 3:37 
Sorry its kinda messy, its from access.. the bold part is the 1 have issue. once againg sorry


SQL
SELECT Product.[Electronic Product Code], Product.[Item Name], IIf([parent - category] Is Null,[name],[Category].[name]=[category].[Category ID].[name]) AS Category , IIf([Parent - Category] Is Not Null,[name],"") AS SubCategory, Location.Country, Location.Building, Location.[Street Address], [Tracking Record].Timestamp, [RFID Reader].[Reader ID]
FROM Location RIGHT JOIN ((([RFID Reader] RIGHT JOIN (Product LEFT JOIN [Tracking Record] ON Product.[Electronic Product Code] = [Tracking Record].[Electronic Product Code]) ON [RFID Reader].[Reader ID] = [Tracking Record].[RFID Reader ID]) LEFT JOIN Has ON Product.[Electronic Product Code] = Has.[Electronic Product Code]) LEFT JOIN Category ON Has.[Category ID] = Category.[Category ID]) ON (Location.Latitude = [Tracking Record].Latitude) AND (Location.Longtitude = [Tracking Record].Longtitude)
WHERE (((Product.[Electronic Product Code]) Like &quot;*&quot; &amp; [forms]![Search History]![tbxEPC] &amp; &quot;*&quot;) AND ((Product.[Item Name]) Like &quot;*&quot; &amp; [forms]![Search History]![tbxProductName] &amp; &quot;*&quot;) AND ((Category.[Category ID])=[forms]![Search History]![cmbCat])) OR (((Product.[Electronic Product Code]) Like &quot;*&quot; &amp; [forms]![Search History]![tbxEPC] &amp; &quot;*&quot;) AND ((Product.[Item Name]) Like &quot;*&quot; &amp; [forms]![Search History]![tbxProductName] &amp; &quot;*&quot;) AND (([forms]![Search History]![cmbCat]) Is Null)) OR (((Product.[Electronic Product Code]) Like &quot;*&quot; &amp; [forms]![Search History]![tbxEPC] &amp; &quot;*&quot;) AND ((Product.[Item Name]) Like &quot;*&quot; &amp; [forms]![Search History]![tbxProductName] &amp; &quot;*&quot;) AND (([forms]![Search History]![cmbCat]) Is Not Null) AND ((Category.[Parent - Category])=[forms]![Search History]![cmbCat]));</pre>

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.