Friday, March 23, 2012
minimum value
or something , the mininum value of the column price must be >= cust * 1,4 ,
the ideia is not permit write in price a value minor of 40 % profit, how i
can make this? i have try with a rule but do not work.
Thanks in advance
Alejandro Carnero"alecarnero" <alecarnero@.uol.com.br> wrote in message
news:%23SNZpoFIGHA.3896@.TK2MSFTNGP15.phx.gbl...
>i have a table with two columns named cust and price, i want to write a
>rule
> or something , the mininum value of the column price must be >= cust * 1,4
> ,
> the ideia is not permit write in price a value minor of 40 % profit, how i
> can make this? i have try with a rule but do not work.
> Thanks in advance
> Alejandro Carnero
>
>
Try a CHECK constraint. Something like:
CREATE TABLE #Foo (
ProductID int NOT NULL PRIMARY KEY,
CustomerID int NOT NULL, -- Foreign Key
BasePrice money CHECK(BasePrice >= 0.00),
CustomerPrice money,
CONSTRAINT profit_margin CHECK(CustomerPrice >= (BasePrice * 1.4))
)
Rick Sawtell
MCT, MCSD, MCDBA
minimum value
or something , the mininum value of the column price must be >= cust * 1,4 ,
the ideia is not permit write in price a value minor of 40 % profit, how i
can make this? i have try with a rule but do not work.
Thanks in advance
Alejandro Carnero
"alecarnero" <alecarnero@.uol.com.br> wrote in message
news:%23SNZpoFIGHA.3896@.TK2MSFTNGP15.phx.gbl...
>i have a table with two columns named cust and price, i want to write a
>rule
> or something , the mininum value of the column price must be >= cust * 1,4
> ,
> the ideia is not permit write in price a value minor of 40 % profit, how i
> can make this? i have try with a rule but do not work.
> Thanks in advance
> Alejandro Carnero
>
>
Try a CHECK constraint. Something like:
CREATE TABLE #Foo (
ProductID int NOT NULL PRIMARY KEY,
CustomerID int NOT NULL, -- Foreign Key
BasePrice money CHECK(BasePrice >= 0.00),
CustomerPrice money,
CONSTRAINT profit_margin CHECK(CustomerPrice >= (BasePrice * 1.4))
)
Rick Sawtell
MCT, MCSD, MCDBA
sql
minimum value
or something , the mininum value of the column price must be >= cust * 1,4 ,
the ideia is not permit write in price a value minor of 40 % profit, how i
can make this? i have try with a rule but do not work.
Thanks in advance
Alejandro Carnero"alecarnero" <alecarnero@.uol.com.br> wrote in message
news:%23SNZpoFIGHA.3896@.TK2MSFTNGP15.phx.gbl...
>i have a table with two columns named cust and price, i want to write a
>rule
> or something , the mininum value of the column price must be >= cust * 1,4
> ,
> the ideia is not permit write in price a value minor of 40 % profit, how i
> can make this? i have try with a rule but do not work.
> Thanks in advance
> Alejandro Carnero
>
>
Try a CHECK constraint. Something like:
CREATE TABLE #Foo (
ProductID int NOT NULL PRIMARY KEY,
CustomerID int NOT NULL, -- Foreign Key
BasePrice money CHECK(BasePrice >= 0.00),
CustomerPrice money,
CONSTRAINT profit_margin CHECK(CustomerPrice >= (BasePrice * 1.4))
)
Rick Sawtell
MCT, MCSD, MCDBA
Wednesday, March 21, 2012
Minimum client connectivity requirement
SQL database (2000), I think I would need to install
MDAC. However, many of these clients are connected with
an extremely slow WAN connection (56K) which makes MDAC
install via login script difficult or impossible. I don't
need the connectivity to all the other DB systems that
MDAC includes. Can I break it up to only install the
necessary components for TCP/IP and Named Pipes
connectivity to SQL server? If so, how can I find out
what files I need, and what if any registry entries need
to be made?
Thanks!
Installing MDAC 2.6 would be the basic requirement.
HTH,
Vinod Kumar
MCSE, DBA, MCAD, MCSD
http://www.extremeexperts.com
Books Online for SQL Server SP3 at
http://www.microsoft.com/sql/techinf...2000/books.asp
"Mark" <anonymous@.discussions.microsoft.com> wrote in message
news:1ce701c42706$37dc7ba0$a001280a@.phx.gbl...
> I have Win9x clients. For them to be able to write to a
> SQL database (2000), I think I would need to install
> MDAC. However, many of these clients are connected with
> an extremely slow WAN connection (56K) which makes MDAC
> install via login script difficult or impossible. I don't
> need the connectivity to all the other DB systems that
> MDAC includes. Can I break it up to only install the
> necessary components for TCP/IP and Named Pipes
> connectivity to SQL server? If so, how can I find out
> what files I need, and what if any registry entries need
> to be made?
> Thanks!
|||This is correct. There is no piecmeal approach to installing the
connectivity components to connect to SQL Server 2000.
Rand
This posting is provided "as is" with no warranties and confers no rights.
Monday, March 12, 2012
Miltivalue Parameters with Max Pool connections
I am trying to write a report with many different records needed (way the database was designed). Client will need multivalue parameter and I have reached max pool connections(can anyone please give me the number).
Normally I would handle this with a stored procedure to create a temp table with the needed information for each section(one row per section), but this will not work with the multivalued parameters(more than one in this report).
Any help on this issue would be appreciated.
Thanks!
Terry
I'm not sure I understand the issue why you are running out of connections, but if all datasets are based on the same data source, you could select the "Use Single Transaction" checkbox on the data source dialog. In that case, all datasets running against that data source will use the same connection. See also: http://msdn2.microsoft.com/en-us/library/ms181198.aspx
-- Robert
|||I have found the data source, but not the single transaction area. Any help in this area would be appreciated. Will have to solve the multivalue parameter issue later. Idea without multivalue parameter would be a stored procedure to fix this.
Have one other idea with @.t table useage.
Thanks for the information.
Terry
|||The "Use single transaction" checkbox is only available in report designer. You cannot change this setting once the report is published.
-- Robert
|||That answered the question. I will have to find it at the start of the development for a new system.
Thanks!
Terry