Solved

Linked MS-SQL Table and lost default values

Posted on 2002-05-13
6
400 Views
Last Modified: 2012-06-27
I have a DB in MS-SQL. Some fields in my table as default values.

When I link my table in MSAccess, I don't see the default values of the fields.

What can I do to see the default values in MSAccess.

Thank you
0
Comment
Question by:cocacola
  • 3
  • 2
6 Comments
 
LVL 54

Expert Comment

by:nico5038
ID: 7007653
The setting of the defaultvalue needs to be in MS SQL, as that's the location where you're real data is stored.
Just use a stored procedure to initialize your default value there.

Nic;o)
0
 

Author Comment

by:cocacola
ID: 7008568
In MSAccess, if a table is empty and you select all rows from it, you will have one empty row with default values on specific fields.

In MSAccess with a table linked from MSSQL, if a table is empty and you select all rows from it, you will have one empty row with blank fields ... no default values.

That`s my problem because I have a screen who is already dealing with an empty row from a MSAccess table (form controls initialises with default value of recordset).  But if I change MSAccess table for a linked table from MS-SQL I have an error because no value on empty recordset on the same screen.


Maybe there`s no answer to that and you cant use default values of MS-SQL in MSAccess.  If so, I will have to fix the codes on my MSAccess application.
0
 

Author Comment

by:cocacola
ID: 7008585
In MSAccess, if a table is empty and you select all rows from it, you will have one empty row with default values on specific fields.

In MSAccess with a table linked from MSSQL, if a table is empty and you select all rows from it, you will have one empty row with blank fields ... no default values.

That`s my problem because I have a screen who is already dealing with an empty row from a MSAccess table (form controls initialises with default value of recordset).  But if I change MSAccess table for a linked table from MS-SQL I have an error because no value on empty recordset on the same screen.


Maybe there`s no answer to that and you cant use default values of MS-SQL in MSAccess.  If so, I will have to fix the codes on my MSAccess application.
0
Highfive + Dolby Voice = No More Audio Complaints!

Poor audio quality is one of the top reasons people don’t use video conferencing. Get the crispest, clearest audio powered by Dolby Voice in every meeting. Highfive and Dolby Voice deliver the best video conferencing and audio experience for every meeting and every room.

 
LVL 54

Expert Comment

by:nico5038
ID: 7009065
Besides the default value setting in the table, you can also set them when displayed on a field.
These settings can differ from the table settings.
These however won't work on the "bare" tables, but they will work on bot "normal" and datasheet forms.
I guess the origin of the row doesn't bother there.

Nic;o)
0
 
LVL 54

Expert Comment

by:nico5038
ID: 7220175

No comment has been added lately, so it's time to clean up this TA.
I will leave a recommendation in Community Support that this question is:
 - PAQ'd and pts refunded
Please leave any comments here within the
next seven days.

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER !

Nic;o)
0
 

Accepted Solution

by:
Jgould earned 0 total points
ID: 7240355
Question has been moved to PAQ and points refunded as per recommendation

Nico > points for you here
http://www.experts-exchange.com/Databases/MS_Access/Q_20340856.html

JGould-EE Moderator
0

Featured Post

Comprehensive Backup Solutions for Microsoft

Acronis protects the complete Microsoft technology stack: Windows Server, Windows PC, laptop and Surface data; Microsoft business applications; Microsoft Hyper-V; Azure VMs; Microsoft Windows Server 2016; Microsoft Exchange 2016 and SQL Server 2016.

Join & Write a Comment

This article is a continuation or rather an extension from Cascading Combos (http://www.experts-exchange.com/A_5949.html) and builds on examples developed in detail there. It should be understandable alone, but I recommend reading the previous artic…
Introduction The Visual Basic for Applications (VBA) language is at the heart of every application that you write. It is your key to taking Access beyond the world of wizards into a world where anything is possible. This article introduces you to…
Familiarize people with the process of utilizing SQL Server stored procedures from within Microsoft Access. Microsoft Access is a very powerful client/server development tool. One of the SQL Server objects that you can interact with from within Micr…
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…

743 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

16 Experts available now in Live!

Get 1:1 Help Now