🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: be.comp.programming
2 messages
2 total messages Started by mheijdeman Wed, 31 Jan 2007 10:39
selectie maken
#561
Author: mheijdeman
Date: Wed, 31 Jan 2007 10:39
7 lines
1292 bytes
Wat gaat hier fout?

Set rs = olddb.OpenRecordset("SELECT naam, micronummer, categorie, " &
dagdienst & " FROM " & tabelnaam & " where micronummer in " & "( " &
strnaamcol & " )" & "and where " & dagdienst & "=" & "A")

krijg namelijk runtime error 3075
Re: selectie maken
#562
Author: Wim Godden
Date: Wed, 31 Jan 2007 11:54
28 lines
1778 bytes
mheijdeman@amphia.nl wrote:
> Wat gaat hier fout?
>
> Set rs = olddb.OpenRecordset("SELECT naam, micronummer, categorie, " &
> dagdienst & " FROM " & tabelnaam & " where micronummer in " & "( " &
> strnaamcol & " )" & "and where " & dagdienst & "=" & "A")
>
> krijg namelijk runtime error 3075
>
>   

Je hebt 2 maal 'where' staan.
Correct is dus :

Set rs = olddb.OpenRecordset("SELECT naam, micronummer, categorie, " &
dagdienst & " FROM " & tabelnaam & " where micronummer in " & "( " &
strnaamcol & " )" & "and " & dagdienst & "=" & "A")



Je hebt ook de inhoud van de variabele dagdienst als kolomnaam staan... 
maar dat kan de bedoeling zijn uiteraard.


Mvg,

Wim Godden
FirstLink Networks
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads