473,654 Members | 2,987 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

what is the equivalent function of CAST in MS Access?

1 New Member
How can I convert my query in MS Access to change date to varchar?

Expand|Select|Wrap|Line Numbers
  1. (SELECT
  2.         LEFT([TIME],10) AS [DATE],
  3.         CAST(LEFT(RIGHT([Time],12),2) AS VARCHAR) AS [TIME],
  4.         COUNT(FORMAT(LEFT(RIGHT([Time],12),2) AS INT)) AS [Number of Calls],
  5.         RIGHT([CNumber],10) AS [CNum]
  6.     FROM 
  7.         [ABC#csv]
This is just a part of my long query.
Jan 24 '14 #1
1 26818
Seth Schrock
2,965 Recognized Expert Specialist
MS Access doesn't have a data type VARCHAR. The CStr() function changes the data type to a string and the Format() function returns a string. Here is a link with more information about the CStr() Function and the Format() Function.
Jan 24 '14 #2

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

Similar topics

10
1694
by: Brad Tilley | last post by:
Is there an easier way to do this: def print_whats_returned(function): print function print type(function)
0
1883
by: Jon | last post by:
I use the following function in Oracle SELEC T decode(status,'A','Active','L','Active','Former') FROM Table What it means is: if status = A, return "Active", if status=L, return "Active", else return "Former" in the select statement. Decode in mysql has nothing to do with this functionality and I didnt see a function while browsing the docs online that did this. Is there an equivalent function in mySQL?
1
1527
by: Dave | last post by:
I have used the 'Date()' function in Access on several occasions to insert the current date into a field. However, I notice that on some computers, the macro fails, saying it doesn't understand teh function. This is despite using the same version of Access (2000) throughout the network, using the same service pack (3) and checking that the msowcf.dll is installed in all cases. I also checked regional settings to see if there was any clue...
4
3874
by: tdick | last post by:
Does anyone know sql of the PV function in Access? (same function in Excel) In access the inputs are PV («rate», «nper», «pmt», «fv», «due») where rate = discount rate, nper = number of payments, pmt = payment) other two are not required. nper is allowed to be a number with decimals, not just an integer. Seeking sql code which will replicate the above, including nper with
1
6490
by: Jaime Leivers | last post by:
Here's a median function in access that you can call in any query. You could change this to any excel function you wanted. Most people can find the windows help file that says how to call an excel function but don't know how to pass an array of the recordset they made into that function. This uses GetRows that nicely creates an array that can be passed into excel. I have this data table for testing. The table name is TestData ...
1
6494
by: neelz | last post by:
Hi Friends, I am porting an application from Linux to Windows. In the source code, <sys/times.h>, time.h etc. header files are included and tms structure, times() function are getting used. I have searched a lot and to my knowledge, I came to the conclusion that GetProcessTime() is the equivalent function in Windows that we can use for Linux times() function. Also, I have researched and concluded that FILETIME is the structure that we can use...
7
4415
by: =?UTF-8?B?QW50w7NuaW8gTWFycXVlcw==?= | last post by:
Hi, Sorry if this's been discussed before, I couldn't find it. As well you know, the ECMAScript standard doesn't include any way to access a function's caller. This has been available on Mozilla and IE as a 'caller' property of function objects, and it seems Konqueror/Safari now have it too. Opera doesn't. And what bothers me is that it is marked as 'deprecated'. I've seen people I respect swear by their lives that it is *good* to
1
4625
by: seanmatthewwalsh | last post by:
Hi I have a website that uses an Access 2003 database. I have controls on my pages that are bound to SqlDataSources that pull data from this database. In a couple of them, I need to use the replace function to replace some text in the results. Access' REPLACE function is only available if executed within the environment, as it's a VBA function, not a SQL function. So how can I implement this is the EASIEST possible way? I don't to...
1
2297
by: Pankaj K Joshi | last post by:
Sir I have Excel function of converting figure into words, now I want to use this function in access. Now how to use it in access? I have two text box in access one is of Amount & other is of Words, In Words Control Source i am using name of function as =Words(). When I run the form in the Words text box it comes as #Name? In Excel i use this function as =Words(Cell Address) & the amount get converted into words.
4
8545
by: kkshansid | last post by:
Kindly help me how to write and call VBA function in access I want to print simple hi function with VBA programming VBA function is not working correctly and asks for parameter value and after giving any rough value such as a then print #name? I write the function by clicking view code Sub hum() prn.Text = "hi" End Sub On textbox with name prn I write =hum() But a popup box opens and ask for Enter parameter value
0
8708
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8489
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
7307
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
1
6161
isladogs
by: isladogs | last post by:
The next Access Europe User Group meeting will be on Wednesday 1 May 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 a new presenter, Adolph Dupré who will be discussing some powerful techniques for using class modules. He will explain when you may want to use classes instead of User Defined Types (UDT). For example, to manage the data in unbound forms. Adolph will...
0
5622
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4149
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
1
2716
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
1
1916
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.
2
1596
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...

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.