Solved

Default value won't insert on new row

Posted on 2008-06-17
2
224 Views
Last Modified: 2010-03-20
I have two default values on two columns. One is GetDate() the other is an integer (6). I am developing a visual basic form based on my database table. When I enter a new row, be it from the form or direct into the db table, the default values will not populate the table unless I re-run the ! SQL. Do I need to create a trigger and if so what is the code? The columns are currently set to NOT NULL.
0
Comment
Question by:teustace
2 Comments
 
LVL 11

Expert Comment

by:CMYScott
ID: 21808581
can you show the code you are using to insert the rows?
0
 

Accepted Solution

by:
teustace earned 0 total points
ID: 21808720
Well, from the front end, using Visual Studio it is just the basic CRUD event when I hit the Save button but nothing happens, (because it is expecting the two values that I have purposely omitted because I am wanting the db to fill them in for me.). When I try entering the data directly into my database it gives a red dot to tell me that "the row was successfully committed to the db however, a problem occurred when attempting to retrieve the data back. So it tells me to re-run the query again. Must be a bug, I guess....
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

Composite queries are used to retrieve the results from joining multiple queries after applying any filters. UNION, INTERSECT, MINUS, and UNION ALL are some of the operators used to get certain desired results.​
It was really hard time for me to get the understanding of Delegates in C#. I went through many websites and articles but I found them very clumsy. After going through those sites, I noted down the points in a easy way so here I am sharing that unde…
Video by: Steve
Using examples as well as descriptions, step through each of the common simple join types, explaining differences in syntax, differences in expected outputs and showing how the queries run along with the actual outputs based upon a simple set of dem…
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…

759 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now