Update multiple hyperlinks at once in Microsoft Access - database

I have thousands of rows in my Microsoft Access DB and I would like to update all values in the column "Documento_Digitalizado". Values in this column are raw text that must be updated to be an hyperlink.
(The hyperlink direction has to be the text value of the cell)
This is my Access DB
This is the way to update them one by one.

First save a copy of your table just in case!
Create a query to up-date your original table Documento_Digitalizado column to show FULL file path if it does not already show it.
Then open your original table in design mode.
Change field type of Documento_Digitalizado from text to hyperlink
save, close.
To bulk edit hyperlink fields change date type from hyperlink to text, create and run query to amend file location, change field data type back to hyperlink

I had to change drive letter in hyperlink. Changed table column to long text from hyperlink and saved. Exported to Excel. Dropped existing rows from table. Bulk changed the drive letter in Excel. Loaded to now empty table. Changed table column to hyperlink.
300 rows of reference document links, 3 minutes to fix.

Related

How do I add a new SQL table to my Excel workbook using PowerPivot

I have pivot table dashboards connected to SQL Server tables via PowerPivot. When the SQL tables have new data added all I have to do is refresh the Excel workbook to see these changes. But every time I add a new column or table in SQL I have to rebuild all these dashboards from scratch by establishing a new connection to the database. How can I simply refresh Excel to see changes I made on the SQL end?
As I mentioned in the comment, you'll have to select the new column(s) in the design of that table.
It comes down to this (source):
In the PowerPivot window, click the Design tab, and in the Properties group, click Table Properties.
The name of the current workbook table is displayed in the Table Name box. The Source Name box contains the name of the table in the external data source. If columns are named differently in the source and in the workbook, you can toggle between the two sets of column names by selecting the options Source or PowerPivot data (workbook).
To change the table that is used as a data source, for Source Name, select a different table than the current one.
Change column mappings if needed:
To add columns that are present in the source but not in the workbook, select the checkbox beside the column name.
The actual data will be loaded into the workbook the next time you refresh.
If some columns in the workbook are no longer available in the current data source, a message appears in the notification area that lists the invalid columns. You do not need to do anything else.

How to store values from a field on excel

this is the first time posting here for me.
I have a quick question about excel. Currently I have an input page where I can input a project name and then fill out details on the project. Is there a way that I can store this information on another sheet? For example, if I type in "Project A" in the project input, then that will be saved in another sheet in a table or something, and the proceeding information (like date, price, etc) will be saved along with it. Then, if I type a new project name in, like "Project B", a new entry will be created with subsequent data.
Thank you!
The ancient Excel data form seems to still exist, even in Excel 2013.
Create a data table with headings and at least one row of data. Select the range and hit Ctrl-T or Insert > Table. This will turn the range into an Excel table.
Now either create a custom group on a ribbon and add the following command to this or your Quick Access Toolbar: All Commands > Form...
Select a cell in the table and hit the Form button that you just inserted into the QAT or the ribbon and you will see a dialog where you can create new rows in the table, and you see a few other buttons to manage data in the table, including deleting rows and searching data in existing rows.
That is the easiest no-code approach.

how to copy structure and data with specific column in visual foxpro

Please help, I have large database in DBF where have 34 column and more than 50k record.
In this case, I need 10 column only from 34 column. Logically, if I delete not necessary column will reduce data load.
So I will copy structure and data from source file with specific column, but I do not know how to do it in visual foxpro.
Will you help me for this case ?
Before and after, thanks for your attention to read my problem.
Regards,
Pathic
Use the following syntax:
SELECT col1,col2,col3,col4,col5,col6,col7,col8,col9,col10 FROM table1 INTO TABLE table2
If you only want to REMOVE the column PERMANENTLY, first, for grins, make a backup copy of the file. Then, make sure you are out of any program using that table and start VFP. In the command window, enter
USE C:\SomePath\YourTable EXCLUSIVE {enter}
*/ Now, get the one column you want copied out... you can just add as many
*/ Columns, such as any primary key reference you may also want to include to.
COPY TheOneColumnYouWant to C:\SomePath\NewTableForThisColumnOnly {enter}
*/ Now, to remove the column from the original table, now that is has been moved
*/ to the "other" table.
MODIFY STRUCTURE {enter}
This brings up a modify table structure where you can alter / delete ANY column. Scroll down the list to the column you want to delete, and at the bottom, click the DELETE button, then click the OK button to confirm structure changes. It will then come back with a confirmation prompt to "Make structure changes permanent?" and select Yes. Column now gone.
An alternative to deleting columns in VFP, you can use Alter Table via...
ALTER table C:\SomePath\YourTable DROP COLUMN TheOneColumnYouWant

Can I edit AutoNumber Column in Access?

I've lost my data in Access base, and I've manage to bring them back but when I copy the values in the table with the AutoNumber Column it increments the numbers.
Is there Any way to change it to int and then bring it back to AutoNumber?
Here is how I managed to do this in Access 2010:
Make a backup of your database. (Just to be safe.)
Right-click on the table in the tables list, and select Export->Excel. Accept all defaults.
Open the table in Excel and make the desired change to the autonumber field.
Open the table and delete all rows
Right-click on table in the tables list, and select Import->Excel
In the options, choose "Append to table" and select the table. Accept defaults for all other options
This might not be a viable solution for a large table. I don't think Excel can handle more than around 65K rows.
Don't copy the data with the user interface, but append it with a query. Because an Autonumber field is just a long integer with a special default value, you can append to it values that already exist. That doesn't work in the UI, but only in SQL.
An Autonumber field has a few other properties that are different from a normal Long Integer field, but in terms of appending data, those are not relevant. One of those properties is that it is not editable once it's populated, and another is that you can have only one in each table.
I've manage to insert the AutoNumber fields by code from c#.
I take all the data I need and just inserted in an empty table.
How are you bringing the data back? It should be possible to append the data from your table and to keep the existing numbers.
It is necessary however, that you paste from an integer field to the autonumber field. You cannot change a field to autonumber from integer once there is data in the field, but you can change to integer from autonumber.
Make backup of your data table. Delete all data form original table and then do compact & repair your database. By doing this, auto number field will be reset at 1. You may now append your data from backup table.
SQL code like
insert into <tablename>
(<column 1>, <column2>, ...)
values
( <value 1>, <value 2>, ...);
will do the trick if you include the autonumber column in your query. It's pretty tedious, but works. You can switch to SQL mode for any old query to enter this text (usually after preparing it in a text editor), or as #Dominic P points out, you can bring up a VBA immediate window and run DoCmd.RunSQL "INSERT INTO ..." which will give you a better editor experience within Access.

Values not showing in Access form combo box

I have an application in Access 2003 that I am working on. In it, I have an employee table, which is connected to two other tables. The two connected tables are tables that hold a few fixed KeyWords. In my main employee table, I just have the ID from the other table, rather than having the whole word.
I wanted to make a form for entering data into these tables, so I made a query from the three tables that shows the all the regular fields of the employee table except instead of those two ID's, I showed the words themselves.
I then made the form and set the query as the RecordSource. The fields that have keywords are Combo boxes on my form, and their ControlSource is the keyword field from the query (like I mentioned earlier, the value can only be one keyword out of a list). Now, the problem I face is this: When I want to see a single record, it shows the correct value in the ComboBox, but when dropdown the menu, it doesnt show any of the other values.
What is the best way to do this? Am I doing this in the wrong way?
Thank you
I'd approach this slightly differently, set the combo box Row Sources to include both the id and text fields (you can hide the ID column if required by setting it's width to zero). Now add the ID fields to the employee query; you shouldn't need to join the other tables to the Employee table in this query, these fields are foreign keys and the combo boxes should show the text for you automatically. Set the form Record Source to this query, now set the combo box Control Source to the appropriate ID value from the form Record Source.
If you let the wizard build a form for you based on the Employee table you will see this approach in action.
ControlSource is the column name of the table where any user entry will be saved.
RowSource is where you type the name of the saved query or manual query typed directly into that field, which is used to provide a list of available drop down options for the combo box.
RowSourceType should be set to Table/Query, which is based on aforementioned RowSource method.
Now to correct the problem of only displaying what you begin to type (i.e. "Allow AutoCorrect" in Property Sheet > Other) or already have saved for that record without other options appearing after clicking the drop down is the following:
In Design View, click the combobox in question.
Property Sheet > Format > Column Count = set the desired number of columns to display in drop down.
Property Sheet > Format > Column Widths = set the desired width of column in the drop down.
Property Sheet > Format > List Width = set the desired width of the drop down itself.
Property Sheet > Data > Bound Column = set to the column of query table (i.e. 1 for ID and 2 for list options, if you only have two entries)
Note: If your desired drop down options are column two and not column one (makes things easier btw) then do the following change from above:
Property Sheet > Format > Column Count = set the desired number of columns to two.
Property Sheet > Format > Column Widths = add two entries 0",1" which means the ID field is not visible (0") and the options field is one-inch.
The easiest way to sort this out in the beginning is to view the column header names to know what you are looking at in the meantime by doing the following:
Property Sheet > Format > Column Heads = set to yes. At least you will know what is showing and whether or not you are on the right track.
I had this same issue in access 2016 and the issue was with my datatype. The combo box didnt accept 'Longtext' so i just changed datatype to 'shorttext' instead and all the values appeared.
You have set the query as the recordsource for the form. A form only shows (and ties to) ONE record at a time.
Since you want the combo box to show all the values, you should set the RecordSource of the ComboBox to your query.

Resources