Re: Convert MDB to ADP
- From: "Jose Perdigao" <JosePerdigao@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Thu, 3 Nov 2005 10:11:10 -0800
Thanks Rob,
I will try to explain what I'm using in access mdb about filter queries
I have a form where I generate reports, queries, forms and by automation I
generate excel reports.
Basicaly I have two functions, one for date, rptDate() and another to
strings rptCtry()
>From a main form, when I select a date and/or coutry from a list box and
combo box, the function rptdate() receive this date and rptCtry() receive the
country.
I give an example:
SELECT B315WellTest.*
FROM B315WellTest
WHERE (((B315WellTest.dDate)=rptDate()) AND
((B315WellTest.Source)=rptCtry()));
For this proceudre all filters running well and quickly and I don't need use
the parameter Forms!formname.selectdate and etc.
I would like use a procedure similar what I am usaing in mdb. I mean, I pass
the date and contry for a table or SP to open queries, forms, reports etc.
Thanks
Jose
"Robert Morley" wrote:
> > 1. Is it possibel to find any function in SQL server to replace Format,
> > left, mid functions?
>
> There's nothing in SQL Server that directly replace the Format() function.
> About the closest you get is STR() to convert numbers to strings, or CONVERT
> to convert a variety of arguments to other formats, including dates to
> strings, etc. Neither of these are anywhere near as functional as the
> Format() command was, though; you're probably going to be stuck making your
> own functions for a lot of your Format() needs.
>
> As for Left() and Right(), they're implemented exactly the same in SQL
> Server, so no problems there, and Mid() is called SubString() but is
> otherwise the same. I seem to remember slight differences in how they
> handle Null's, empty strings, and cases where you ask for more characters
> than there are; also SubString() doesn't support the two-parameter format
> that Mid() does (i.e., you can't use just SubString(MyString,2) to return
> everything from the second character on like you could with Mid()). You
> should probably double-check the docs for SQL Server if these are a concern
> for you.
>
> > 2. I know, we can not use my VBA functions in SQL server.
> > In mdb, I have my functions to filter records open forms, queries,
> > reports
> > based date and countries selected from a list box existing in a form.
> > Question.
> > How can I filter queries (views, SP), forms, reports in ADP project, based
> > a
> > parameter selected from a list box or combo box?
>
> If you're just using Me.Filter, you can pretty much leave your code
> unchanged. The only slight changes would be things like single-quotes
> around strings instead of double-quotes, no #'s around dates (I think you
> can only use single-quotes there as well, and provide a formatted string as
> a date...or use CAST/CONVERT). If you're using other methods, post a few
> more specifics, and I or someone else will undoubtedly be able to help you
> further.
>
>
>
> Rob
>
>
>
.
- Follow-Ups:
- Re: Convert MDB to ADP
- From: Robert Morley
- Re: Convert MDB to ADP
- References:
- Re: Convert MDB to ADP
- From: Robert Morley
- Re: Convert MDB to ADP
- Prev by Date: Re: ADP works, ADE on same machine does not
- Next by Date: Re: Convert MDB to ADP
- Previous by thread: Re: Convert MDB to ADP
- Next by thread: Re: Convert MDB to ADP
- Index(es):
Relevant Pages
|