473,383 Members | 1,862 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,383 software developers and data experts.

Help.Enquires about SQL query

17
May I know if I want to add in a INSERT INTO statement do I have to declare anything above in the VB.Net programme?example,

INSERT INTO Carpark_table (Carplate, date, TimeIn)
VALUES (car_plate, datestr, timestr)

when I debug the INSERT and VALUES are considered as errors where declarations are needed
Oct 10 '07 #1
4 1200
debasisdas
8,127 Expert 4TB
Question moved to .NET Forum.
Oct 10 '07 #2
jrtox
89
May I know if I want to add in a INSERT INTO statement do I have to declare anything above in the VB.Net programme?example,

INSERT INTO Carpark_table (Carplate, date, TimeIn)
VALUES (car_plate, datestr, timestr)

when I debug the INSERT and VALUES are considered as errors where declarations are needed

Hello,
I cant help you with VB.NET, i really dont know it its Same format in VB6
Anyway In VB6, the Format will be

Expand|Select|Wrap|Line Numbers
  1. INSERT INTO Carpark_table (Carplate, date, TimeIn)
  2. VALUES ('" & car_plate & "', '" & datestr & "', '" & timestr & "')
  3.  
Tell me if its Works.

Regards
Phils Ervin
Oct 10 '07 #3
debasisdas
8,127 Expert 4TB
try using this

"INSERT INTO Carpark_table (Carplate, date, TimeIn)
VALUES ('" & car_plate & "', '" & datestr & "', '" & timestr & "')"
Oct 10 '07 #4
You should have to establish a connection.
Then give a command text specifying INSERT/DELETE/or any query.
Then give execute query.
It wil work.
Im saying u the steps. U should develop the code

Thank U
Jeen
Oct 10 '07 #5

Sign in to post your reply or Sign up for a free account.

Similar topics

11
by: James | last post by:
My form and results are on one page. If I use : if ($Company) { $query = "Select Company, Contact From tblworking Where ID = $Company Order By Company ASC"; }
4
by: Surendra | last post by:
I have this query that I need to use in an Update statement to populate a field in the table by the value of Sq ---------------------------------------------------------------------------- Inline...
9
by: netpurpose | last post by:
I need to extract data from this table to find the lowest prices of each product as of today. The product will be listed/grouped by the name only, discarding the product code - I use...
3
by: Gary | last post by:
Hello, I am trying to write a query and getting a little confused. My problem: I send enquiries to partners from 12:00am to 11:59pm each day. I have ten partners, and each partner has a...
9
by: Dom Boyce | last post by:
Hi First up, I am using MS Access 2002. I have a database which records analyst rating changes for a list of companies on a daily basis. Unfortunately, the database has been set up (by my...
8
by: Andrew McNab | last post by:
Hi folks, I have a problem with an MS Access SQL query which is being used in an Access Report, and am wondering if anyone can help. Basically, my query (shown below) gets some records from a...
5
by: Steve Patrick | last post by:
Hi All You guys are my last hope, despite spending money on books and hours reading them I still can not achieve the results I need. I have designed a database in Access 2000 based on 1 table,...
4
by: Alan Lane | last post by:
Hello world: I'm including both code and examples of query output. I appologize if that makes this message longer than it should be. Anyway, I need to change the query below into a pivot table...
6
by: Takeadoe | last post by:
Dear NG, Can someone assist me with writing the little code that is needed to run an update table query each time the database is opened? From what I've been able to glean from this group, the...
47
by: Jo | last post by:
Hi there, I'm Jo and it's the first time I've posted here. I'm in process of creating a database at work and have come a little unstuck.....I'm a bit of a novice and wondered if anyone could...
1
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...
0
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 3 Apr 2024 starting at 18:00 UK time (6PM UTC+1) and finishing by 19:30 (7.30PM). In this session, we are pleased to welcome former...
0
by: ryjfgjl | last post by:
In our work, we often need to import Excel data into databases (such as MySQL, SQL Server, Oracle) for data analysis and processing. Usually, we use database tools like Navicat or the Excel import...
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
1
by: nemocccc | last post by:
hello, everyone, I want to develop a software for my android phone for daily needs, any suggestions?
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.